{% include "kjs/eagleye/templates/widgets/form_style.html" %}

{% csrf_token %}
{% if register_form.errors %}
    {% for error in register_form.errors.items %}
        {% if error.0 == "__all__" %}
            <div class="allFormFieldErrors">
                <ul>
                    {% for errorInfo in error.1 %}
                        <li>{{ errorInfo }}</li>
                    {% endfor %}
                </ul>
            </div>
        {% endif %}
    {% endfor %}
{% endif %}
{% for field in register_form %}
    <div class="formField">
        <label for="{{ field.auto_id }}">{{ field.label }}</label>
        {{ field }}
        <input type="hidden" name="fieldHelpText" value="{{ field.help_text }}"/>
        {% if field.errors %}
            <ul class="fieldErrors">
                {% for error in field.errors %}
                    <li>
                        {{ error }}
                    </li>
                {% endfor %}
            </ul>
        {% endif %}
    </div>
{% endfor %}

{% include "kjs/eagleye/templates/widgets/form_action.html" %}
